#include "CommandUp.h"
#include "MaMap.h"
#include "Model.h"
void CommandUp::execute(){
	int x = block->getX();
	int y = block->getY();
	Model::getInstance()->getMaMap()->moveBlock(block, x, y+1,false);
	y++;
	block->setPosition(x,y);
	block->pushMovement(Vec3(x,y,0));
}
void CommandUp::undo(){
	int x = block->getX();
	int y = block->getY();
	Model::getInstance()->getMaMap()->moveBlock(block, x, y-1,true);
	y--;
	block->setPosition(x,y);
	block->pushMovement(Vec3(x,y,0));
}